package TREE1;
import TREE.*;
public class test {
    public static void main(String[] args){
        tree a=new BinTree();
    	 Node c1=new Node(1);
    	 Node c2=new Node(2);
    	 Node c3=new Node(3);
    	 Node c4=new Node(4);
    	 Node c5=new Node(5);
    	 Node c6=new Node(6);
         Node c7=new Node(7);
    	 Node p1=a.insert(c1,0,null);
    	 Node p2=a.insert(c1,1,c2);
    	 Node p3=a.insert(c1,-1,c3);
    	 Node p4=a.insert(c2,1,c4);
    	 Node p5=a.insert(c2,-1,c5);
    	 Node p6=a.insert(c3,1,c6);
    	 System.out.println(" "+a.BiTreeDepth());
    	 a.LevelTraverse(c1);
    	 a.PreOrderTreverse(c1);
    	 System.out.println(" "+a.Parent(c4).data);
         System.out.println(" ");
         a.Assign(c2,9);
         System.out.println(""+c2.data);
         a.delete(c2,1);
         a.LevelTraverse(c1);
         System.out.println(" ");
         System.out.println(" "+a.LeftChild(c3).data);
         //System.out.println(" "+a.LeftSibling(c6).data);
    }
}
